package login.DAO;

import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;

/**
 *
 * @author Javier
 */
public class LoginDAO {

    public Connection login(String user, String password, String host, String port) throws SQLException {
        String server = "jdbc:mysql://"+host+":"+port+"/";
        DriverManager.registerDriver(new com.mysql.jdbc.Driver());
        Connection connection = DriverManager.getConnection(server,user,password);
        return connection;
    }

    
}
